
/**  
 * @Title: TestThreads.java
 * @Package com.finfosoft.threads
 * @author FY(543943341@qq.com)
 * @date 2018年1月8日
 * @version V1.0 
 * @Description:
 *    功能说明
 */
    
package com.finfosoft.threads;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;

/**
 * @ClassName: TestThreads
 * @Description: 
 *    功能描述
 * @author FY(543943341@qq.com)
 * @date 2018年1月8日
 *
 */

public class TestThreads {
	
	
	public static void main(String[] args) {
		
		AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(TaskExecutorConfig.class);
		
		AsyncTaskService asyncTaskService = context.getBean(AsyncTaskService.class);
		
		for (int i = 0; i < 10; i++) {
			
			asyncTaskService.executeAsyncTask(i);
			asyncTaskService.exectureAsyncTaskPlus(i);
		}
		context.close();
	}
}
